package com.simple.entity;

/**
 * 状态码
 * 三个参数：状态码、提示语句、图标（参考layui弹出层）
 */
public enum StatusCode {
    SUCCESS("200","操作成功","1"),
    FAIL("500","操作失败","2"),
    
    PERMISSION_FAIL("400","暂无权限操作","4"),
    
    NULL_SUCCESS("200",""),
    NULL_FAIL("500",""),

    LOGIN_SUCCESS("200","登录成功","1"),
    LOGIN_FAIL("500","登录失败","2"),

    DELETE_SUCCESS("200","删除成功","1"),
    DELETE_FAIL("500","删除失败","2"),

	ADD_SUCCESS("200","添加成功","1"),
	ADD_FAIL("500","添加失败","2"),
	
	EDIT_SUCCESS("200","修改成功","1"),
	EDIT_FAIL("500","修改失败","2");
	

    private String code;
    private String message;
    private String icon;

    private StatusCode(String code, String message) {
        this.code = code;
        this.message = message;
    }

    private StatusCode(String code, String message,String icon) {
        this.message = message;
        this.code = code;
        this.icon=icon;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public String getIcon() {
        return icon;
    }

    public void setIcon(String icon) {
        this.icon = icon;
    }
}
